package org.wk.user.enums;

import org.springframework.expression.spel.ast.OpNE;

/**
 * @ClassName	: IdentityType
 * @Package		：org.wk.common.enums
 * @Author df.w 
 * @Create Time	：2018年5月3日 下午4:35:29
 * @Description	: 身份类型
 */ 
public enum IdentityType {
	AVERAGE(0,"普通会员"),
	ONEVIP (1,"一钻会员"),
	TWOVIP (2,"二钻会员"),
	THREEVIP (3,"三钻会员"),
	FOURVIP (4,"四钻会员"),
	FIVEVIP (5,"五钻会员"),
	SIXVIP (6,"六钻会员"),
	SEVENVIP (7,"七钻会员"),
	EIGHTVIP (8,"八钻会员"),
	NINEVIP (9,"九钻会员"),
	TENVIP (10,"十钻会员"),
	ELEVENVIP (11,"十一钻会员"),
	TWELVEVIP (12,"十二钻会员"),
	THIRTEENVIP (13,"十三钻会员");
	private int code;
	private String name;
	private IdentityType(int code, String name) {
		this.code = code;
		this.name = name;
	}
	
	
	public static IdentityType containsCode(int code) {
		for (IdentityType item : IdentityType.values()) {
			if (item.getCode() == code) {
				return item;
			}
		}		
		return null;
	}
			
	/**
	 * @return the code
	 */
	
	public int getCode() {
		return code;
	}
	
	/**
	 * @param code 要设置的 code
	 */
	
	public void setCode(int code) {
		this.code = code;
	}
	/**
	 * @return the name
	 */
	
	public String getName() {
		return name;
	}
	
	/**
	 * @param name 要设置的 name
	 */
	
	public void setName(String name) {
		this.name = name;
	}
	
	
	
	
	
}
